package com.rockcent.mall.lib.dto;

import com.rockcent.common.domain.DtoEntity;
import com.rockcent.mall.lib.domain.MerchantOrderItem;
import com.rockcent.mall.lib.domain.OrderEvent;
import com.rockcent.mall.lib.domain.enumclass.*;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * Created by HK on 16/10/10.
 * 商家订单dto
 */
public class MerchantOrderDto extends DtoEntity {

    //订单号
    private String orderNum;
    //平台 订单id
    private Long mallOrderId;
    //平台订单号
    private String mallOrderNum;
    //平台id
    private Long mallId;
    //客户id
    private Long customerId;
    //客户名称
    private String customerName;
    //客户分销码
    private String customerShareCode;
    //商户id
    private Long merchantId;
    //商户名称
    private String merchantName;
    //商户门店 id
    private Long merchantStoreId;
    //优惠金额
    private BigDecimal discountAmount;
    //收货人地址
    private String address;
    //收货人
    private String shoppingMan;
    //收货人电话号码
    private String shoppingManPhone;
    //订单状态 WAIT_PAYING("待支付"), CANCEL("取消"), PAYED("已支付"), WAIT_SHIPPED("等待发货"), SHIPPED("已发货"), SHOP_PICKUP("到店自提"), PART_SHOP_PICKUP("部分到店自提"), CONFIRM_PICKUP("确认自提"), CONFIRM("已确认"), WAIT_USE("待使用"), PART_USE("部分使用"), USED("已使用"), FINISHED("已完成"), APPLY_REJECT("申请退货"), FINISHED_REJECT("已完成退货"), APPLY_REFUND("申请退款"), FINISHED_REFUND("已完成退款")
    private String status;
    //评价状态
    private String evaluateStatus;
    //物流单号
    private String logisticsNumber;
    //物流公司ID(其它为0)
    private Long logisticsId;
    //物流公司名称
    private String logisticsName;
    //发货时间
    private Date dateDelivered;
    //收货时间
    private Date dateReceived;
    //备注
    private String remark;
    //物流种类 SHOP_PICKUP("到店自提"), SHIPPING("物流")
    private String productShoppingType;
    //订单类型 GOODS("实物商品"), SERVICE("到店服务")
    private String orderType;
    //结算状态 WAIT_SETTLE("待结算"), PART_SETTLE("部分结算"), SETTLED("已结算")
    private SettlementStatus settleStatus;
    //渠道分销码
    private String channelSalesCode;
    //支付方式
    private String paymentMethod;
    //支付时间
    private Date datePaid;
    //物流种类 SELF("自营订单"), MARKET("分销订单")
    private String merchantOrderExtType;
    //SOURCE("下单源"), MARKET("分销下单")
    private String sourceType;
    //订单分销来源id
    private String extSourceOrderId;

    //开始时间
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private String beginDate;

    //结束时间
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private String endDate;

    //产品类型
    private String productType;

    //产品来源
    private String productSource;
    //商家角色。当订单为分销订单时,用于区分供应商或者分销商
    private String merchantRole;

    //礼包id
    private Long giftId;
    //礼包名称
    private String giftName;
    //礼包数量
    private Integer giftNum;
    //礼包在mallOrder里面的总价
    private BigDecimal totalAmount;
    //物流公司编码
    private String logisticsCode;
    //门店电话
    private String merchantStoreMobile;
    //门店名称
    private String merchantStoreName;
    //分销订单号
    private String marketOrderNum;

    //订单所含产品
    private List<MerchantOrderItemDto> merchantOrderItemDtoList;
    private List<MerchantOrderItem> merchantOrderItemList;

    //订单事件跟踪
    private List<OrderEvent> orderEventList;
    private BigDecimal shareFee;


    public String getEvaluateStatus() {
        return evaluateStatus;
    }

    public void setEvaluateStatus(String evaluateStatus) {
        this.evaluateStatus = evaluateStatus;
    }

    public Long getMallOrderId() {
        return mallOrderId;
    }

    public void setMallOrderId(Long mallOrderId) {
        this.mallOrderId = mallOrderId;
    }

    public Long getMallId() {
        return mallId;
    }

    public void setMallId(Long mallId) {
        this.mallId = mallId;
    }

    public Long getCustomerId() {
        return customerId;
    }

    public void setCustomerId(Long customerId) {
        this.customerId = customerId;
    }

    public String getCustomerName() {
        return customerName;
    }

    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }

    public Long getMerchantId() {
        return merchantId;
    }

    public void setMerchantId(Long merchantId) {
        this.merchantId = merchantId;
    }

    public String getMerchantName() {
        return merchantName;
    }

    public void setMerchantName(String merchantName) {
        this.merchantName = merchantName;
    }



    public BigDecimal getDiscountAmount() {
        return discountAmount;
    }

    public void setDiscountAmount(BigDecimal discountAmount) {
        this.discountAmount = discountAmount;
    }

    public String getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(String orderNum) {
        this.orderNum = orderNum;
    }

    public String getMallOrderNum() {
        return mallOrderNum;
    }

    public void setMallOrderNum(String mallOrderNum) {
        this.mallOrderNum = mallOrderNum;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getShoppingMan() {
        return shoppingMan;
    }

    public void setShoppingMan(String shoppingMan) {
        this.shoppingMan = shoppingMan;
    }

    public String getShoppingManPhone() {
        return shoppingManPhone;
    }

    public void setShoppingManPhone(String shoppingManPhone) {
        this.shoppingManPhone = shoppingManPhone;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getLogisticsNumber() {
        return logisticsNumber;
    }

    public void setLogisticsNumber(String logisticsNumber) {
        this.logisticsNumber = logisticsNumber;
    }

    public Long getLogisticsId() {
        return logisticsId;
    }

    public void setLogisticsId(Long logisticsId) {
        this.logisticsId = logisticsId;
    }

    public String getLogisticsName() {
        return logisticsName;
    }

    public void setLogisticsName(String logisticsName) {
        this.logisticsName = logisticsName;
    }

    public Date getDateDelivered() {
        return dateDelivered;
    }

    public void setDateDelivered(Date dateDelivered) {
        this.dateDelivered = dateDelivered;
    }

    public Date getDateReceived() {
        return dateReceived;
    }

    public void setDateReceived(Date dateReceived) {
        this.dateReceived = dateReceived;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public SettlementStatus getSettleStatus() {
        return settleStatus;
    }

    public void setSettleStatus(SettlementStatus settleStatus) {
        this.settleStatus = settleStatus;
    }

    public String getPaymentMethod() {
        return paymentMethod;
    }

    public void setPaymentMethod(String paymentMethod) {
        this.paymentMethod = paymentMethod;
    }

    public Date getDatePaid() {
        return datePaid;
    }

    public void setDatePaid(Date datePaid) {
        this.datePaid = datePaid;
    }

    public String getExtSourceOrderId() {
        return extSourceOrderId;
    }

    public void setExtSourceOrderId(String extSourceOrderId) {
        this.extSourceOrderId = extSourceOrderId;
    }

    public Long getMerchantStoreId() {
        return merchantStoreId;
    }

    public void setMerchantStoreId(Long merchantStoreId) {
        this.merchantStoreId = merchantStoreId;
    }

    public String getChannelSalesCode() {
        return channelSalesCode;
    }

    public void setChannelSalesCode(String channelSalesCode) {
        this.channelSalesCode = channelSalesCode;
    }

    public String getCustomerShareCode() {
        return customerShareCode;
    }

    public void setCustomerShareCode(String customerShareCode) {
        this.customerShareCode = customerShareCode;
    }

    public String getBeginDate() {
        return beginDate;
    }

    public void setBeginDate(String beginDate) {
        this.beginDate = beginDate;
    }

    public String getEndDate() {
        return endDate;
    }

    public void setEndDate(String endDate) {
        this.endDate = endDate;
    }

    public String getProductType() {
        return productType;
    }

    public void setProductType(String productType) {
        this.productType = productType;
    }

    public String getProductSource() {
        return productSource;
    }

    public void setProductSource(String productSource) {
        this.productSource = productSource;
    }

    public List<MerchantOrderItemDto> getMerchantOrderItemDtoList() {
        return merchantOrderItemDtoList;
    }

    public void setMerchantOrderItemDtoList(List<MerchantOrderItemDto> merchantOrderItemDtoList) {
        this.merchantOrderItemDtoList = merchantOrderItemDtoList;
    }

    public String getProductShoppingType() {
        return productShoppingType;
    }

    public void setProductShoppingType(String productShoppingType) {
        this.productShoppingType = productShoppingType;
    }

    public String getOrderType() {
        return orderType;
    }

    public void setOrderType(String orderType) {
        this.orderType = orderType;
    }

    public String getMerchantOrderExtType() {
        return merchantOrderExtType;
    }

    public void setMerchantOrderExtType(String merchantOrderExtType) {
        this.merchantOrderExtType = merchantOrderExtType;
    }

    public String getSourceType() {
        return sourceType;
    }

    public void setSourceType(String sourceType) {
        this.sourceType = sourceType;
    }

    public Long getGiftId() {
        return giftId;
    }

    public void setGiftId(Long giftId) {
        this.giftId = giftId;
    }

    public String getGiftName() {
        return giftName;
    }

    public void setGiftName(String giftName) {
        this.giftName = giftName;
    }

    public Integer getGiftNum() {
        return giftNum;
    }

    public void setGiftNum(Integer giftNum) {
        this.giftNum = giftNum;
    }

    public BigDecimal getTotalAmount() {
        return totalAmount;
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public String getMerchantRole() {
        return merchantRole;
    }

    public void setMerchantRole(String merchantRole) {
        this.merchantRole = merchantRole;
    }

    public String getLogisticsCode() {
        return logisticsCode;
    }

    public void setLogisticsCode(String logisticsCode) {
        this.logisticsCode = logisticsCode;
    }

    public List<OrderEvent> getOrderEventList() {
        return orderEventList;
    }

    public void setOrderEventList(List<OrderEvent> orderEventList) {
        this.orderEventList = orderEventList;
    }

    public String getMerchantStoreMobile() {
        return merchantStoreMobile;
    }

    public void setMerchantStoreMobile(String merchantStoreMobile) {
        this.merchantStoreMobile = merchantStoreMobile;
    }

    public String getMerchantStoreName() {
        return merchantStoreName;
    }

    public void setMerchantStoreName(String merchantStoreName) {
        this.merchantStoreName = merchantStoreName;
    }

    public String getMarketOrderNum() {
        return marketOrderNum;
    }

    public void setMarketOrderNum(String marketOrderNum) {
        this.marketOrderNum = marketOrderNum;
    }

    public List<MerchantOrderItem> getMerchantOrderItemList() {
        return merchantOrderItemList;
    }

    public void setMerchantOrderItemList(List<MerchantOrderItem> merchantOrderItemList) {
        this.merchantOrderItemList = merchantOrderItemList;
    }

    public BigDecimal getShareFee() {
        return shareFee;
    }

    public void setShareFee(BigDecimal shareFee) {
        this.shareFee = shareFee;
    }

    @Override
    public String toString() {
        return "MerchantOrderDto{" +
                "orderNum='" + orderNum + '\'' +
                ", mallOrderId=" + mallOrderId +
                ", mallOrderNum='" + mallOrderNum + '\'' +
                ", mallId=" + mallId +
                ", customerId=" + customerId +
                ", customerName='" + customerName + '\'' +
                ", customerShareCode='" + customerShareCode + '\'' +
                ", merchantId=" + merchantId +
                ", merchantName='" + merchantName + '\'' +
                ", merchantStoreId=" + merchantStoreId +
                ", discountAmount=" + discountAmount +
                ", address='" + address + '\'' +
                ", shoppingMan='" + shoppingMan + '\'' +
                ", shoppingManPhone='" + shoppingManPhone + '\'' +
                ", status='" + status + '\'' +
                ", evaluateStatus='" + evaluateStatus + '\'' +
                ", logisticsNumber='" + logisticsNumber + '\'' +
                ", logisticsId=" + logisticsId +
                ", logisticsName='" + logisticsName + '\'' +
                ", dateDelivered=" + dateDelivered +
                ", dateReceived=" + dateReceived +
                ", remark='" + remark + '\'' +
                ", productShoppingType='" + productShoppingType + '\'' +
                ", orderType='" + orderType + '\'' +
                ", settleStatus=" + settleStatus +
                ", channelSalesCode='" + channelSalesCode + '\'' +
                ", paymentMethod='" + paymentMethod + '\'' +
                ", datePaid=" + datePaid +
                ", merchantOrderExtType='" + merchantOrderExtType + '\'' +
                ", sourceType='" + sourceType + '\'' +
                ", extSourceOrderId='" + extSourceOrderId + '\'' +
                ", beginDate='" + beginDate + '\'' +
                ", endDate='" + endDate + '\'' +
                ", productType='" + productType + '\'' +
                ", productSource='" + productSource + '\'' +
                ", merchantRole='" + merchantRole + '\'' +
                ", giftId=" + giftId +
                ", giftName='" + giftName + '\'' +
                ", giftNum=" + giftNum +
                ", totalAmount=" + totalAmount +
                ", logisticsCode='" + logisticsCode + '\'' +
                ", merchantStoreMobile='" + merchantStoreMobile + '\'' +
                ", merchantStoreName='" + merchantStoreName + '\'' +
                ", marketOrderNum='" + marketOrderNum + '\'' +
                ", merchantOrderItemDtoList=" + merchantOrderItemDtoList +
                ", merchantOrderItemList=" + merchantOrderItemList +
                ", orderEventList=" + orderEventList +
                ", shareFee=" + shareFee +
                '}';
    }
}
